<html>
<script type="text/javascript" src="<?=$ROOT_JS_DIR?>/common.js"></script>
<script type="text/javascript" src="<?=$ROOT_JS_DIR?>/jsmasks.js"></script>
<body>
<h1>Loading data...</h1>
<?

$FileName       = "ais_transaction_custlist_rpc.php";
$HTMLFormName   = "CustomerGrid";

if (GetParam("nobkt","")) {
	$SQL = "SELECT * FROM ais_piutang WHERE nobkt = '".GetParam("nobkt","")."' AND normut=999";
	//print $SQL;
	$Result = $DBConnection->dbc->get_row($SQL);
	if ($Result) {
		$js_script  = "<script>\n";
		$js_script .= "  oMask = new Mask('#,###.#0', 'number');\n";
		$js_script .= "  parent.document.".$HTMLFormName.".uraian1.value = '".$Result->uraian."';\n";
		$js_script .= "  parent.document.".$HTMLFormName.".jumlah1.value = oMask.format('".$Result->jumlah."');\n";
		$js_script .= "  parent.document.".$HTMLFormName.".rate.value = oMask.format('".$Result->rate."');\n";
		$js_script .= "  parent.document.".$HTMLFormName.".curr.value = '".$Result->curr."';\n";
		$js_script .= "  parent.document.".$HTMLFormName.".skada1.value = '".$Result->skada."';\n";
		$js_script .= "  parent.document.".$HTMLFormName.".untush1.value = '".$Result->untush."';\n";
		$js_script .= "  parent.document.".$HTMLFormName.".noorder1.value = '".$Result->noorder."';\n";

		$js_script .= "</script>\n";
		print $js_script;
	}
}
?>